package com.young.ums.model;

import java.util.List;

/**
 * 权限相关参数
 * @author imrookie
 * @date 2018/10/24
 */
public class AuthorityParameter {

    //ums数据权限相关字段
    private Boolean enableAuth;//权限标志,为true时表示启用权限控制
    private String loginUserId;//当前登录用户id
    private List<Dept> manageRangeList;//管理范围

    /**
     * 判断是否启用权限
     * @return 当且仅当enableAuth=true时返回true
     */
    public boolean enableAuth(){
        return enableAuth != null && enableAuth == true;
    }

    public Boolean getEnableAuth() {
        return enableAuth;
    }

    public void setEnableAuth(Boolean enableAuth) {
        this.enableAuth = enableAuth;
    }

    public String getLoginUserId() {
        return loginUserId;
    }

    public void setLoginUserId(String loginUserId) {
        this.loginUserId = loginUserId;
    }

    public List<Dept> getManageRangeList() {
        return manageRangeList;
    }

    public void setManageRangeList(List<Dept> manageRangeList) {
        this.manageRangeList = manageRangeList;
    }
}
